package com.neusoft.mid.msf.common.constant;

/**
 * @program: pangu
 * @description: 系统Api返回码定义
 * @author: fengjd
 * @create: 2022-07-22 09:37
 **/
public enum ApiCode {
     STATUS_SUCCESS(200,"处理成功")
    ,STATUS_FAILED(500,"处理失败")
    ,AUTH_ERROR(1001,"用户名或密码错误")
    ,TOKEN_EXPIRED_ERROR(1002,"token已过期")
    ,TOKEN_ERROR(1002,"token非法")
    ,SERVER_INTERNAL_ERROR(2001,"系统内部错误")
    ,GATEWAY_ROUTE_ERROR(2002,"系统路由错误")
    ,USER_PERMESSION_ERROR(2003,"用户无权限")
    ,FLOW_CONTROL_ERROR(2004,"Blocked by FlowControl")
    ,COMMUNICATION_ERROR(2005,"Proxy Communication Error")
    ,REQUEST_TIME_OUT(2006,"Proxy Read Timeout")
    ,ILLEGAL_ARGUMENT(2007,"参数不合法")
    ;
    private final Integer code;
    private final String name;

    ApiCode(Integer code, String name) {
        this.code = code;
        this.name = name;
    }

    public Integer getCode() {
        return code;
    }

    public String getName() {
        return name;
    }
}
